package day03;

public class OperDemo3 {
    public static void main(String[] args) {
        //逻辑运算符 ||或(一真必真),&&与(一假必假),!非(取反)
        int a = 5,b=10,c=5;
        /*boolean b1 = b>a && b<c;
        System.out.println(b1);
        System.out.println(b<=c && b>a);//t && f = f
        System.out.println(a==b && c>b);//f && t = t
        System.out.println(b!=c && a<b);//t && t = t*/

        /*int age = 40;
        System.out.println(age>=18 && age<=50);//年龄在18到50之间
        int score = 80;
        System.out.println(score>=0 && score<=100);//成绩在0到100之间*/

        /*boolean b2 = !(a<b);
        System.out.println(b2);//!true = fasle;
        System.out.println(!(a>b));//!fasle=true;*/

        /*boolean b3 = a>b && c++>2;
        System.out.println(b3);//false
        System.out.println(c);//5 发生短路了*/

       /* boolean b4 = a<b || c++>2;
        System.out.println(b4);//true
        System.out.println(c);//5 发生短路了*/


    }
}
